package com.anytrek.cloudcommon.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 *
 * @TableName t_commodity
 */
@TableName(value ="t_commodity")
@Data
@NoArgsConstructor
@AllArgsConstructor
public class CommodityEntity {

    /**
     * 主键
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    /**
     * 商品名称
     */
    @TableField(value = "`name`")
    private String name;

    /**
     * 价格
     */
    @TableField(value = "price")
    private Integer price;

    /**
     * 库存
     */
    @TableField(value = "stock")
    private Integer stock;
}